from apps.vadmin.op_drf.models import BaseModel
from django.db.models import CharField, FloatField, IntegerField


class Kq_All_Pumps(BaseModel):
    type = CharField(max_length=255, verbose_name='型号')
    flow = CharField(max_length=255, verbose_name='流量')
    height = CharField(max_length=255, verbose_name='扬程')
    power = FloatField(verbose_name='功率')
    rev = IntegerField(verbose_name='转速', blank=True, null=True)
    calibre = IntegerField(verbose_name='口径', blank=True, null=True)
    compType = CharField(max_length=32, verbose_name='所属公司类型')
    kind = CharField(max_length=32, verbose_name='水泵类型')
    url1 = CharField(max_length=255, verbose_name='安装图纸', blank=True, null=True)
    url2 = CharField(max_length=255, verbose_name='性能图纸', blank=True, null=True)
    url3 = CharField(max_length=255, verbose_name='安装图纸2', blank=True, null=True)
    url4 = CharField(max_length=255, verbose_name='性能图纸2', blank=True, null=True)

    class Meta:
        verbose_name = '水泵型号信息表'
        verbose_name_plural = verbose_name

    def __str__(self):
        return f"{self.id}"
